package com.darwin.darwinBitmapEngine.events
{
	import com.darwin.darwinBitmapEngine.core.IContainer;
	import com.darwin.darwinBitmapEngine.core.INode;
	
	import flash.events.Event;
	
	/**
	 * 节点相关事件 
	 * @author lipi
	 */
	public class NodeEvent extends Event
	{
		public function NodeEvent(type:String)
		{
			super(type, false, false);
		}
		
		private var _nodeTarget:INode;
		
		/**
		 * 触发鼠标事件的目标节点，对于Node nodeTarget是Node本身，对于容器对象
		 * nodeTarget是容器的子节点
		 */
		public function set nodeTarget(value:INode):void
		{
			_nodeTarget = value;
		}
		
		public function get nodeTarget():INode
		{
			return _nodeTarget;
		}
		
		private var _containerTarget:IContainer;
		/**
		 * 触发对象的容器节点，对于Node containerTarget是Node本身，对于容器对象
		 * containerTarget是容器
		 * @return 
		 */
		public function get containerTarget():IContainer
		{
			return _containerTarget;
		}

		public function set containerTarget(value:IContainer):void
		{
			_containerTarget = value;
		}
		
		
		public static const MOUSE_DOWN:String = "mouseDown";
		public static const MOUSE_CLICK:String = "mouseClick";
		public static const MOUSE_OVER:String = "mouseOver";
		public static const MOUSE_OUT:String = "mouseOut";
		
		/**
		 * Node 动画播放完成 
		 */		
		public static const MOVIE_COMPLETE:String = "movieComplete";
		
	}
}